package com.ycz.pattern.behaviour.commandpattern;

/**
 * @author yancz
 * @ClassName BuyStock
 * @description: TODO
 * @date 2023-11-28 17:19:27
 * @version: 1.0
 */
public class BuyStock implements Order {

    private Stock stock;

    public BuyStock(Stock stock) {
        this.stock = stock;
    }

    @Override
    public void execute() {
        stock.buy();
    }
}
